Security News
The Unpaid Backbone of Open Source: Solo Maintainers Face Increasing Security Demands
Solo open source maintainers face burnout and security challenges, with 60% unpaid and 60% considering quitting.
@aws-crypto/raw-keyring
Advanced tools
The AWS Encryption SDK for JavaScript is a client-side encryption library designed to make it easy for everyone to encrypt and decrypt data using industry standards and best practices. It uses a data format compatible with the AWS Encryption SDKs in other
@aws-crypto/raw-keyring is a package provided by AWS that allows developers to use raw keyrings for cryptographic operations. This package is part of the AWS Encryption SDK and is used to encrypt and decrypt data using raw cryptographic keys.
Encrypting Data
This feature allows you to encrypt data using a raw AES keyring. The code sample demonstrates how to create a RawAesKeyringNode and use it to encrypt a plaintext string.
const { RawAesKeyringNode } = require('@aws-crypto/raw-keyring');
const { encrypt } = require('@aws-crypto/client-node');
const keyName = 'example-key-name';
const keyNamespace = 'example-key-namespace';
const unencryptedMasterKey = Buffer.from('00112233445566778899aabbccddeeff00112233445566778899aabbccddeeff', 'hex');
const keyring = new RawAesKeyringNode({
keyName,
keyNamespace,
unencryptedMasterKey
});
const plaintext = 'Hello, World!';
(async () => {
const { result } = await encrypt(keyring, plaintext);
console.log(result);
})();
Decrypting Data
This feature allows you to decrypt data that was encrypted using a raw AES keyring. The code sample demonstrates how to create a RawAesKeyringNode and use it to decrypt an encrypted data buffer.
const { RawAesKeyringNode } = require('@aws-crypto/raw-keyring');
const { decrypt } = require('@aws-crypto/client-node');
const keyName = 'example-key-name';
const keyNamespace = 'example-key-namespace';
const unencryptedMasterKey = Buffer.from('00112233445566778899aabbccddeeff00112233445566778899aabbccddeeff', 'hex');
const keyring = new RawAesKeyringNode({
keyName,
keyNamespace,
unencryptedMasterKey
});
const encryptedData = /* previously encrypted data */;
(async () => {
const { plaintext } = await decrypt(keyring, encryptedData);
console.log(plaintext.toString());
})();
The 'crypto' module in Node.js provides cryptographic functionality that includes a set of wrappers for OpenSSL's hash, HMAC, cipher, decipher, sign, and verify functions. Unlike @aws-crypto/raw-keyring, it does not provide a high-level abstraction for key management and encryption/decryption operations.
Node-forge is a JavaScript library that provides a native implementation of TLS (and various other cryptographic tools) in JavaScript. It offers more granular control over cryptographic operations compared to @aws-crypto/raw-keyring, but does not integrate directly with AWS services.
Stanford Javascript Crypto Library (SJCL) is a library for cryptography in JavaScript. It is designed to be secure, fast, and easy to use. SJCL provides a variety of cryptographic primitives but does not offer the same level of integration with AWS services as @aws-crypto/raw-keyring.
The AWS Encryption SDK for JavaScript is a client-side encryption library designed to make it easy for everyone to encrypt and decrypt data using industry standards and best practices. It uses a data format compatible with the AWS Encryption SDKs in other languages. For more information on the AWS Encryption SDKs in all languages, see the Developer Guide.
This packages is not intended for direct use by clients. To get started with the AWS Encryption SDK for JavaScript, follow the instructions in the README.
This SDK is distributed under the Apache License, Version 2.0, see LICENSE.txt and NOTICE.txt for more information.
FAQs
The AWS Encryption SDK for JavaScript is a client-side encryption library designed to make it easy for everyone to encrypt and decrypt data using industry standards and best practices. It uses a data format compatible with the AWS Encryption SDKs in other
The npm package @aws-crypto/raw-keyring receives a total of 213,603 weekly downloads. As such, @aws-crypto/raw-keyring popularity was classified as popular.
We found that @aws-crypto/raw-keyring demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Solo open source maintainers face burnout and security challenges, with 60% unpaid and 60% considering quitting.
Security News
License exceptions modify the terms of open source licenses, impacting how software can be used, modified, and distributed. Developers should be aware of the legal implications of these exceptions.
Security News
A developer is accusing Tencent of violating the GPL by modifying a Python utility and changing its license to BSD, highlighting the importance of copyleft compliance.